<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script>
        // 声明变量
        var num = 10, num2 = 20, temp;
        temp = num2;
        num2 = num;
        num = temp;
        console.log('num:' + num);
        console.log('num2' + num2);
    </script>
</head>
<body>
    
</body>
</html>